package com.example.zq.player.linked_database_interface;

import android.content.Intent;

import com.example.zq.player.linked_database_interface.base.RequestInterface;
import com.example.zq.player.linked_database_interface.bean.User;
import com.example.zq.player.pager.MyPager;

import retrofit2.Retrofit;
import retrofit2.converter.gson.GsonConverterFactory;

public class GlobalInformation {
    private static Retrofit retrofit = new Retrofit.Builder()
            .baseUrl(RequestInterface.basePath)
            .addConverterFactory(GsonConverterFactory.create())
            .build();
    private static User user;

    public static Retrofit getRetrofit(){
        return GlobalInformation.retrofit;
    }

    public static void setUser(User user){
        GlobalInformation.user = user;
    }

    public static User getUser(){
        return user;
    }

    public static void clearUser(){
        user = null;
    }
}
